home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 52 / Amiga Format AFCD52 (Issue 136, May 2000).iso / -serious- / programming / other / dopus412-gpl / dopus_disk / diskop.h < prev    next >
C/C++ Source or Header  |  2000-02-28  |  4KB  |  142 lines

  1. /*
  2.  
  3. Directory Opus 4
  4. Original GPL release version 4.12
  5. Copyright 1993-2000 Jonathan Potter
  6.  
  7. This program is free software; you can redistribute it and/or
  8. modify it under the terms of the GNU General Public License
  9. as published by the Free Software Foundation; either version 2
  10. of the License, or (at your option) any later version.
  11.  
  12. This program is distributed in the hope that it will be useful,
  13. but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15. GNU General Public License for more details.
  16.  
  17. You should have received a copy of the GNU General Public License
  18. along with this program; if not, write to the Free Software
  19. Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  20.  
  21. All users of Directory Opus 4 (including versions distributed
  22. under the GPL) are entitled to upgrade to the latest version of
  23. Directory Opus version 5 at a reduced price. Please see
  24. http://www.gpsoft.com.au for more information.
  25.  
  26. The release of Directory Opus 4 under the GPL in NO WAY affects
  27. the existing commercial status of Directory Opus 5.
  28.  
  29. */
  30.  
  31. #include <fctype.h>
  32. #include <string.h>
  33. #include <stdlib.h>
  34. #include <stdarg.h>
  35. #include <exec/types.h>
  36. #include <exec/memory.h>
  37. #include <exec/execbase.h>
  38. #include <dos/dos.h>
  39. #include <dos/dosextens.h>
  40. #include <dos/filehandler.h>
  41. #include <intuition/intuitionbase.h>
  42. #include <intuition/sghooks.h>
  43. #include <workbench/workbench.h>
  44. #include <workbench/startup.h>
  45. #include <devices/trackdisk.h>
  46. #include <datatypes/datatypesclass.h>
  47. #include <proto/all.h>
  48.  
  49. #include "dopusbase.h"
  50. #include "dopuspragmas.h"
  51. #include "requesters.h"
  52. #include "stringdata.h"
  53.  
  54. #include "dopusmessage.h"
  55.  
  56. #include "functions.h"
  57. #include "diskstrings.h"
  58.  
  59. extern struct DOpusBase *DOpusBase;
  60. extern struct IntuitionBase *IntuitionBase;
  61. extern struct GfxBase *GfxBase;
  62. extern struct Library *IconBase;
  63. extern struct ExecBase *SysBase;
  64. extern struct DosLibrary *DOSBase;
  65.  
  66. #define ERROR_FAILED  -1
  67. #define ERROR_MEMORY  -2
  68. #define ERROR_BITMAP  -3
  69. #define ERROR_VERIFY  -4
  70. #define ERROR_ABORTED -5
  71.  
  72. struct BitmapBlock {
  73.     ULONG Checksum;
  74.     ULONG Bitmap[127];
  75. };
  76.  
  77. struct BitmapExtension {
  78.     ULONG BitmapPointers[127];
  79.     ULONG    BitmapExtension;
  80. };
  81.  
  82. struct RootDirectory {
  83.     ULONG    PrimaryType;
  84.     ULONG    HeaderKey;
  85.     ULONG    WhoKnows0;
  86.     ULONG    HashTableSize;
  87.     ULONG    WhoKnows1;
  88.     ULONG    Checksum;
  89.     ULONG HashTable[72];
  90.     ULONG    BitmapFlag;
  91.     ULONG    BitmapPointers[25];
  92.     ULONG    BitmapExtension;
  93.     struct DateStamp LastRootChange;
  94.     UBYTE    DiskName[32];
  95.     ULONG    WhoKnows2[2];
  96.     struct DateStamp LastDiskChange;
  97.     struct DateStamp CreationDate;
  98.     ULONG    NextHash;
  99.     ULONG    ParentDir;
  100.     ULONG    WhoKnows3;
  101.     ULONG    SecondaryType;
  102. };
  103.  
  104. extern ULONG BitTable[32];
  105.  
  106. extern struct TagItem format_name_gadget[];
  107. extern struct TagItem format_ffs_gadget[];
  108. extern struct TagItem format_international_gadget[];
  109. extern struct TagItem format_caching_gadget[];
  110. extern struct TagItem format_trashcan_gadget[];
  111. extern struct TagItem format_verify_gadget[];
  112. extern struct TagItem format_format_gadget[];
  113. extern struct TagItem format_quickformat_gadget[];
  114. extern struct TagItem format_cancel_gadget[];
  115.  
  116. extern struct TagItem diskcopy_verify_gadget[];
  117. extern struct TagItem diskcopy_bumpnames_gadget[];
  118. extern struct TagItem diskcopy_diskcopy_gadget[];
  119. extern struct TagItem diskcopy_cancel_gadget[];
  120. extern struct TagItem diskcopy_source_list[];
  121. extern struct TagItem diskcopy_destination_list[];
  122.  
  123. extern struct TagItem install_ffs_gadget[];
  124. extern struct TagItem install_install_gadget[];
  125. extern struct TagItem install_noboot_gadget[];
  126. extern struct TagItem install_cancel_gadget[];
  127.  
  128. extern struct DiskObject trashcanicon_icon;
  129.  
  130. extern ULONG bootblock_13[13],bootblock_20[24];
  131.  
  132. struct DeviceHandle {
  133.     struct MsgPort *device_port;
  134.     struct IOExtTD *device_req;
  135.     struct FileSysStartupMsg *startup;
  136.     struct DosEnvec *dosenvec;
  137. };
  138.  
  139. extern struct DefaultString default_strings[];
  140.  
  141. #define STRING_VERSION 1
  142.